<fieldset id="fd1" style="width:80%;margin:5px;">
	<legend><span>派工设备查询</span></legend>
	<div class="fieldset-body">
		<table class="form-table" border="0" cellpadding="1" cellspacing="2">
			<tr>
				<td class="form-label" style="width:80px;">类型:</td>
				<td style="width:150px"><input id="brand" class="mini-combobox" textField="name" valueField="id" data="JS.CONST[3]" allowInput="true" showNullItem="true" nullItemText="请选择..." style="width:100%;"/></td>
				<td class="form-label" style="width:80px;">品牌:</td>
				<td style="width:150px"><input id="pattern" class="mini-combobox" textField="name" valueField="id" data="JS.CONST[4]" allowInput="true" showNullItem="true" nullItemText="请选择..." style="width:100%;"/></td>
				<td class="form-label" style="width:80px;">名称:</td>
				<td style="width:150px"><input id="name" class="mini-textbox" emptyText="请输入名称" style="width:100%;"/></td>
				<td style="width:150px"><a class="mini-button" id="search" iconCls="icon-search">查询...</a></td>
			</tr>
		</table>
	</div>
</fieldset>
<div class="mini-toolbar" style="padding:0px;margin:6px 0px 0px 0px;border-bottom:0;width:100%;">
	<table style="width:100%;">
		<tr>
			<td style="width:100%;">
				<a class="mini-button" iconCls="icon-addnew" id="buttonAdd" onclick="newRow()" plain="true">增加派工设备</a>
				<!--
				<span class="separator"></span>
				<a class="mini-button" iconCls="icon-download" id="exportExcel" onclick="ExportExcel()" plain="true">导出Excel</a>
				<span class="separator"></span>
				<a class="mini-button" iconCls="icon-print" id="gridPrint" plain="true">打印</a>
				-->
			</td>
		</tr>
	</table>
</div>
<div id="grid1" class="mini-datagrid" allowAlternating="true" idField="id" pageSize="20" style="width:100%;height:80%;" url="/basic/deviceList" >
	<div property="columns">
		<div type="indexcolumn" headerAlign="center">编号</div>
		<div field="name" width="250" headerAlign="center" allowSort="true">名称<input property="editor" class="mini-textbox" required="true" emptyText="必须输入名称" style="width:100%;"/></div>           
		<div field="types" width="120" allowSort="true">类型<input property="editor" class="mini-combobox" textField="name" valueField="name" data="JS.CONST[3]" allowInput="true" style="width:100%;"/></div>                               
		<div field="brand" width="120" allowSort="true">品牌<input property="editor" class="mini-textbox" required="true" style="width:100%;"/></div>
		<div field="pattern" width="120" allowSort="true">型号<input property="editor" class="mini-textbox" required="true" style="width:100%;"/></div>
		<div field="remark" width="200" headerAlign="center" allowSort="true">备注<input property="editor" class="mini-textarea" emptyText="请输入备注" style="width:100%;height:40px;"/></div>
		<div field="updated" width="100" headerAlign="center" align="center" dateFormat="yyyy-MM-dd" allowSort="true">更新日期</div>
		<div name="action" width="120" headerAlign="center" align="center" renderer="onActionRenderer" cellStyle="padding:0;">操作</div>                
	</div>
</div>
<iframe id="exportIFrame" style="display:none;"></iframe>
<script type="text/javascript">
mini.parse();
var urlDel = "/basic/deviceDel";
var urlUpd = "/basic/deviceUpd";
var grid = mini.get("grid1");
grid.load();

$("#search").click(function(){
	grid.load({brand:mini.get("brand").getText(),pattern:mini.get("pattern").getText(),name:mini.get("name").getValue()});
});
</script>